package com.weisiqian.study.springcloud.ribbonhystrix.controller;

import com.weisiqian.study.springcloud.ribbonhystrix.service.HelloService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("/hello")
public class HelloController {

    @Autowired
    HelloService helloService;

    @RequestMapping("/say")
    @ResponseBody
    public String sayHello(String name){
        return helloService.sayHello(name);
    }

}
